<template>
  <div>
    <el-form ref="form" :model="form" label-width="100px">
      <el-form-item label="持卡人">
        <el-input class="w500" v-model="form.account"></el-input>
      </el-form-item>
      <el-form-item label="发行卡名称">
        <el-input class="w500" v-model="form.name"></el-input>
      </el-form-item>
      <el-form-item label="发行卡标识">
        <el-input class="w500" v-model="form.name_en"></el-input>
      </el-form-item>
      <el-form-item label="卡号">
        <el-input class="w500" v-model="form.number"></el-input>
      </el-form-item>
      <el-form-item label="状态">
        <el-radio-group v-model="form.status">
          <el-radio label="0">未审核</el-radio>
          <el-radio label="1">审核通过</el-radio>
          <el-radio label="2">审核失败</el-radio>
        </el-radio-group>
      </el-form-item>
      <el-form-item>
        <el-button @click="goBack">返回</el-button>
      </el-form-item>
    </el-form>
  </div>
</template>

<script>
  import { mapState } from 'vuex'
  export default {
    data: function () {
      return {
      }
    },
    computed: {
      ...mapState({
        form: state => state.bank.saveData
      })
    },
    created () {
      this.form.status = String(this.form.status)
    },
    methods: {
      goBack () {
        this.$router.go(-1)
      }
    }
  }
</script>
